package top.melody.ecommerce.platform.api.service;


import top.melody.ecommerce.common.util.page.PageRows;
import top.melody.ecommerce.common.util.page.Pagination;
import top.melody.ecommerce.platform.EcommerceException;
import top.melody.ecommerce.platform.api.domain.account.Account;

import java.util.List;

/**
 * @author: melody
 * @groupId:rd
 * @createdate:2016-10-18
 * @mail: blentle.huan.ren@gmail.com
 * @description:
 * @since: 1.0
 */
public interface AccountService {
    //sign up
    Account signUp(Account account) throws EcommerceException;
    //get account by primary key
    Account getAccount(int accountId) throws EcommerceException;
    //get account by userId
    Account getAccount(String userId) throws EcommerceException;
    //get account by userId
    Account getAccountByMobile(String mobile) throws EcommerceException;

    Account updateAccount(Account account) throws EcommerceException;

    PageRows<Account> queryByPage(Account account, Pagination page) throws EcommerceException;

    // 根据主键查询用户
    Account getAccountUser(Integer accountId) throws EcommerceException;
}
